using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._Table
{
    /// <summary>
    /// <para>Create Unregistered Table</para>
    /// <para>Creates an empty table in a database or enterprise geodatabase. The table is not registered with the geodatabase.</para>
    /// <para>在数据库或企业级地理数据库中创建空表。该表未注册到地理数据库。</para>
    /// </summary>    
    [DisplayName("Create Unregistered Table")]
    public class CreateUnRegisteredTable : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public CreateUnRegisteredTable()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_out_path">
        /// <para>Table Location</para>
        /// <para>The enterprise geodatabase or database in which the output table will be created.</para>
        /// <para>将在其中创建输出表的企业级地理数据库或数据库。</para>
        /// </param>
        /// <param name="_out_name">
        /// <para>Table Name</para>
        /// <para>The name of the table to be created.</para>
        /// <para>要创建的表的名称。</para>
        /// </param>
        public CreateUnRegisteredTable(object _out_path, object _out_name)
        {
            this._out_path = _out_path;
            this._out_name = _out_name;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Create Unregistered Table";

        public override string CallName => "management.CreateUnRegisteredTable";

        public override List<string> AcceptEnvironments => ["configKeyword", "workspace"];

        public override object[] ParameterInfo => [_out_path, _out_name, _template, _config_keyword, _out_table];

        /// <summary>
        /// <para>Table Location</para>
        /// <para>The enterprise geodatabase or database in which the output table will be created.</para>
        /// <para>将在其中创建输出表的企业级地理数据库或数据库。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Table Location")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_path { get; set; }


        /// <summary>
        /// <para>Table Name</para>
        /// <para>The name of the table to be created.</para>
        /// <para>要创建的表的名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Table Name")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_name { get; set; }


        /// <summary>
        /// <para>Template Table Name</para>
        /// <para>An existing table or list of tables with fields and attribute schema used to define the fields in the output table.</para>
        /// <para>包含字段和属性架构的现有表或表列表，用于定义输出表中的字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Template Table Name")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _template { get; set; } = null;


        /// <summary>
        /// <para>Configuration Keyword</para>
        /// <para><xdoc>
        ///   <para>Specifies the default storage parameters (configurations) for geodatabases in a relational database management system (RDBMS). This setting is applicable only when using enterprise geodatabase tables.</para>
        ///   <para>Configuration keywords are set by the database administrator.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定关系数据库管理系统 （RDBMS） 中地理数据库的默认存储参数（配置）。此设置仅在使用企业级地理数据库表时适用。</para>
        ///   <para>配置关键字由数据库管理员设置。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Configuration Keyword")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _config_keyword { get; set; } = null;


        /// <summary>
        /// <para>Output Table</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Table")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_table { get; set; }


        public CreateUnRegisteredTable SetEnv(object configKeyword = null, object workspace = null)
        {
            base.SetEnv(configKeyword: configKeyword, workspace: workspace);
            return this;
        }

    }

}